<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<%@ taglib uri="/WEB-INF/tlds/att.tld" prefix="att"%>
<html>
<head>
<meta name="decorator" content="default" />
<script src="${staticPath}/lib/accounting/0.3.2/accounting.min.js"
	type="text/javascript"></script>
<script type="text/javascript">

	$(document).ready(function() {
                 //货币格式化
                 $('[data-accounting]').each(
						function() {
							var $this = $(this);
								if ($this.attr("data-accounting-precision")
										&& "" != $this.attr("data-accounting-precision")) {
											$this.html(accounting.formatMoney(
												$this.attr("data-accounting"),
													"¥ ",$this.attr("data-accounting-precision") * 1));
											} else {
												$this.html(accounting.formatMoney(
													$this.attr("data-accounting"),
														"¥ "));
											}
										});
             	parent.document.getElementById("paymentDetailFrame").height = document.body.scrollHeight;
					});
	
</script>
</head>
<body>
<form:form name="listForm" modelAttribute="stmError" method="post" class="form-inline" role="form">
	    <input type="hidden" name="deleteIds" >
		<div class="o-l-search-builder f_9">
			<table class="table table-striped table-hover o-l-table table-bordered" id="table1">
				<thead class="t_1">
					<tr>
						<th>行号</th>
						<th>公司代码</th>
						<th>费用类型</th>
						<th>费用名称</th>
						<th>扣款项目</th>
						<th>应扣金额</th>
						<th>实扣金额</th>
						<th>开票类型</th>
						<th>合同号</th>
						<th>临时费用单号</th>
						<th>备注</th>
					</tr>
				</thead>
				<tbody>
					<c:forEach items="${page.list}" var="paymentDetail">
						<tr>
							<td>${paymentDetail.statementLineItem}</td>
							<td>${paymentDetail.companyCode}</td>
							<td>${paymentDetail.costType}</td>
							<td>${paymentDetail.costName}</td>
							<td>${paymentDetail.debitItem}</td>
							<td data-accounting="${paymentDetail.shouldDeductAmount}"
								data-accounting-precision="2"></td>
							<td data-accounting="${paymentDetail.realDeductAmount}"
								data-accounting-precision="2">${paymentDetail.realDeductAmount}</td>
							<td>${paymentDetail.invoiceType}</td>
							<td>${paymentDetail.contractNumber}</td>
							<td>${paymentDetail.id}</td>
							<td>${paymentDetail.auditingRemark}</td>
						</tr>
					</c:forEach>
				</tbody>
			</table>
        </div>
		<pager:pager pageSize="${page.pageSize}" pageNo="${page.pageNo}" url="" total="${page.total}"/>
		<script type="text/javascript" src="${staticPath}/js/list.js"></script>
  </form:form>
</body>
</html>